home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / lib / mozilla-firefox / include / content / nsISyncLoadDOMService.h < prev    next >
C/C++ Source or Header  |  2006-05-08  |  8KB  |  176 lines

  1. /*
  2.  * DO NOT EDIT.  THIS FILE IS GENERATED FROM nsISyncLoadDOMService.idl
  3.  */
  4.  
  5. #ifndef __gen_nsISyncLoadDOMService_h__
  6. #define __gen_nsISyncLoadDOMService_h__
  7.  
  8.  
  9. #ifndef __gen_nsISupports_h__
  10. #include "nsISupports.h"
  11. #endif
  12.  
  13. /* For IDL files that don't want to include root IDL files. */
  14. #ifndef NS_NO_VTABLE
  15. #define NS_NO_VTABLE
  16. #endif
  17. class nsIURI; /* forward declaration */
  18.  
  19. class nsIDOMDocument; /* forward declaration */
  20.  
  21. class nsIChannel; /* forward declaration */
  22.  
  23.  
  24. /* starting interface:    nsISyncLoadDOMService */
  25. #define NS_ISYNCLOADDOMSERVICE_IID_STR "96a13c30-695a-492c-918b-04ae3edb4e4c"
  26.  
  27. #define NS_ISYNCLOADDOMSERVICE_IID \
  28.   {0x96a13c30, 0x695a, 0x492c, \
  29.     { 0x91, 0x8b, 0x04, 0xae, 0x3e, 0xdb, 0x4e, 0x4c }}
  30.  
  31. /*************************************************************************
  32.  *                                                                       *
  33.  *                          **** NOTICE ****                             *
  34.  *                                                                       *
  35.  *    nsISyncLoadDOMService defines synchronous methods to download      *
  36.  *    data from the network.  Any delays from the server will            *
  37.  *    appear as a hang in the mozilla UI.  Therefore, this interface     *
  38.  *    should be avoided as much as possible.                             *
  39.  *                                                                       *
  40.  *    Don't make me come over there!!                                    *
  41.  *                                                                       *
  42.  *                                                                       *
  43.  ************************************************************************/
  44. /**
  45.  * The nsISyncDOMLoadService interface can be used to synchronously load
  46.  * a document.
  47.  */
  48. class NS_NO_VTABLE nsISyncLoadDOMService : public nsISupports {
  49.  public: 
  50.  
  51.   NS_DEFINE_STATIC_IID_ACCESSOR(NS_ISYNCLOADDOMSERVICE_IID)
  52.  
  53.   /**
  54.      * Synchronously load the document from the specified channel.
  55.      *
  56.      * @param aChannel   The channel to load the document from.
  57.      * @param aLoaderURI URI of loading document. For security checks
  58.      *                   null if no securitychecks should be done
  59.      *
  60.      * @returns The document loaded from the URI.
  61.      */
  62.   /* nsIDOMDocument loadDocument (in nsIChannel aChannel, in nsIURI aLoaderURI); */
  63.   NS_IMETHOD LoadDocument(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval) = 0;
  64.  
  65.   /* nsIDOMDocument loadDocumentAsXML (in nsIChannel aChannel, in nsIURI aLoaderURI); */
  66.   NS_IMETHOD LoadDocumentAsXML(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval) = 0;
  67.  
  68.   /**
  69.      * Synchronously load an XML document from the specified
  70.      * channel. The channel must be possible to open synchronously.
  71.      *
  72.      * @param aChannel   The channel to load the document from.
  73.      * @param aLoaderURI URI of loading document. For security checks
  74.      *                   null if no securitychecks should be done
  75.      *
  76.      * @returns The document loaded from the URI.
  77.      */
  78.   /* nsIDOMDocument loadLocalDocument (in nsIChannel aChannel, in nsIURI aLoaderURI); */
  79.   NS_IMETHOD LoadLocalDocument(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval) = 0;
  80.  
  81.   /**
  82.      * Synchronously load the xbl-document from the specified channel. The channel
  83.      * must be possible to open synchronously.
  84.      *
  85.      * @param aChannel   The channel to load the document from.
  86.      *
  87.      * @returns The document loaded from the URI.
  88.      */
  89.   /* nsIDOMDocument loadLocalXBLDocument (in nsIChannel aChannel); */
  90.   NS_IMETHOD LoadLocalXBLDocument(nsIChannel *aChannel, nsIDOMDocument **_retval) = 0;
  91.  
  92. };
  93.  
  94. /* Use this macro when declaring classes that implement this interface. */
  95. #define NS_DECL_NSISYNCLOADDOMSERVICE \
  96.   NS_IMETHOD LoadDocument(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval); \
  97.   NS_IMETHOD LoadDocumentAsXML(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval); \
  98.   NS_IMETHOD LoadLocalDocument(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval); \
  99.   NS_IMETHOD LoadLocalXBLDocument(nsIChannel *aChannel, nsIDOMDocument **_retval); 
  100.  
  101. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  102. #define NS_FORWARD_NSISYNCLOADDOMSERVICE(_to) \
  103.   NS_IMETHOD LoadDocument(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval) { return _to LoadDocument(aChannel, aLoaderURI, _retval); } \
  104.   NS_IMETHOD LoadDocumentAsXML(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval) { return _to LoadDocumentAsXML(aChannel, aLoaderURI, _retval); } \
  105.   NS_IMETHOD LoadLocalDocument(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval) { return _to LoadLocalDocument(aChannel, aLoaderURI, _retval); } \
  106.   NS_IMETHOD LoadLocalXBLDocument(nsIChannel *aChannel, nsIDOMDocument **_retval) { return _to LoadLocalXBLDocument(aChannel, _retval); } 
  107.  
  108. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  109. #define NS_FORWARD_SAFE_NSISYNCLOADDOMSERVICE(_to) \
  110.   NS_IMETHOD LoadDocument(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->LoadDocument(aChannel, aLoaderURI, _retval); } \
  111.   NS_IMETHOD LoadDocumentAsXML(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->LoadDocumentAsXML(aChannel, aLoaderURI, _retval); } \
  112.   NS_IMETHOD LoadLocalDocument(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->LoadLocalDocument(aChannel, aLoaderURI, _retval); } \
  113.   NS_IMETHOD LoadLocalXBLDocument(nsIChannel *aChannel, nsIDOMDocument **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->LoadLocalXBLDocument(aChannel, _retval); } 
  114.  
  115. #if 0
  116. /* Use the code below as a template for the implementation class for this interface. */
  117.  
  118. /* Header file */
  119. class nsSyncLoadDOMService : public nsISyncLoadDOMService
  120. {
  121. public:
  122.   NS_DECL_ISUPPORTS
  123.   NS_DECL_NSISYNCLOADDOMSERVICE
  124.  
  125.   nsSyncLoadDOMService();
  126.  
  127. private:
  128.   ~nsSyncLoadDOMService();
  129.  
  130. protected:
  131.   /* additional members */
  132. };
  133.  
  134. /* Implementation file */
  135. NS_IMPL_ISUPPORTS1(nsSyncLoadDOMService, nsISyncLoadDOMService)
  136.  
  137. nsSyncLoadDOMService::nsSyncLoadDOMService()
  138. {
  139.   /* member initializers and constructor code */
  140. }
  141.  
  142. nsSyncLoadDOMService::~nsSyncLoadDOMService()
  143. {
  144.   /* destructor code */
  145. }
  146.  
  147. /* nsIDOMDocument loadDocument (in nsIChannel aChannel, in nsIURI aLoaderURI); */
  148. NS_IMETHODIMP nsSyncLoadDOMService::LoadDocument(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval)
  149. {
  150.     return NS_ERROR_NOT_IMPLEMENTED;
  151. }
  152.  
  153. /* nsIDOMDocument loadDocumentAsXML (in nsIChannel aChannel, in nsIURI aLoaderURI); */
  154. NS_IMETHODIMP nsSyncLoadDOMService::LoadDocumentAsXML(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval)
  155. {
  156.     return NS_ERROR_NOT_IMPLEMENTED;
  157. }
  158.  
  159. /* nsIDOMDocument loadLocalDocument (in nsIChannel aChannel, in nsIURI aLoaderURI); */
  160. NS_IMETHODIMP nsSyncLoadDOMService::LoadLocalDocument(nsIChannel *aChannel, nsIURI *aLoaderURI, nsIDOMDocument **_retval)
  161. {
  162.     return NS_ERROR_NOT_IMPLEMENTED;
  163. }
  164.  
  165. /* nsIDOMDocument loadLocalXBLDocument (in nsIChannel aChannel); */
  166. NS_IMETHODIMP nsSyncLoadDOMService::LoadLocalXBLDocument(nsIChannel *aChannel, nsIDOMDocument **_retval)
  167. {
  168.     return NS_ERROR_NOT_IMPLEMENTED;
  169. }
  170.  
  171. /* End of implementation class template. */
  172. #endif
  173.  
  174.  
  175. #endif /* __gen_nsISyncLoadDOMService_h__ */
  176.